﻿/****************************** Module Header ******************************\
 * Module Name:  tGeneralCouponsRecipient.cs
 * Module Version:  1.0.0 (2014-01-22)
 * Copyright (c) AnyEB.Com (14507247@qq.com)
 * 
 * This source is subject to the GPL License.
 * See http://www.gnu.org/licenses/gpl.html.
 * All other rights reserved.
 * 
 * THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, 
 * EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED 
 * WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR PURPOSE.
\***************************************************************************/

using System;

namespace UCL.Data.ORM.UMD
{
    /// <summary>
    /// 通用-优惠券领用表 数据实体类
    /// </summary>
    [DBTable(Common = "通用-优惠券领用表")]
    public class tGeneralCouponsRecipient
    {
        /// <summary>
        /// 优惠券号码(流水号)
        /// </summary>
        public string SerialNo { get { return _SerialNo; } set { _SerialNo = value; } }

        [DBColumn(Alias = "优惠券条码", Common = "序列号或流水号", IsKey = true, Length = "32")]
        private string _SerialNo;

        /// <summary>
        /// 优惠券面值
        /// </summary>
        public decimal FaceValue { get { return _FaceValue ?? default(decimal); } set { _FaceValue = value; } }

        [DBColumn(Alias = "优惠券面值")]
        private decimal? _FaceValue;

        /// <summary>
        /// 客户编号
        /// </summary>
        public string CustomerNo { get { return _CustomerNo; } set { _CustomerNo = value; } }

        [DBColumn(Alias = "客户编号", Length = "32")]
        private string _CustomerNo;

        /// <summary>
        /// 订单编号
        /// </summary>
        public string OrderNo { get { return _OrderNo; } set { _OrderNo = value; } }

        [DBColumn(Alias = "订单编号", Length = "32")]
        private string _OrderNo;

        /// <summary>
        /// 状态(0=已使用,1=未使用,4=已作废)
        /// </summary>
        public short State { get { return _State ?? default(short); } set { _State = value; } }

        [DBColumn(Alias = "状态", DefaultValue = "0")]
        private short? _State;

        /// <summary>
        /// 创建时间
        /// </summary>
        public DateTime CreatedTime { get { return _CreatedTime ?? default(DateTime); } set { _CreatedTime = value; } }

        [DBColumn(Alias = "创建时间", DefaultValue = "getdate()")]
        private DateTime? _CreatedTime;

        /// <summary>
        /// 领取时间(激活时间)
        /// </summary>
        public DateTime ActivationTime { get { return _ActivationTime ?? default(DateTime); } set { _ActivationTime = value; } }

        [DBColumn(Alias = "领取时间(激活时间)", CanBeNull = true)]
        private DateTime? _ActivationTime;

        /// <summary>
        /// 过期时间
        /// </summary>
        public DateTime ExpirationTime { get { return _ExpirationTime ?? default(DateTime); } set { _ExpirationTime = value; } }

        [DBColumn(Alias = "过期时间", CanBeNull = true)]
        private DateTime? _ExpirationTime;
    }
}
